import { http } from "@/utils/http";

/** 获取数字人列表 */
export function getMyHumanInfoList(data?: object): Promise<MyHumanInfoData[]> {
  return http.request({
    url: "/digitalHuman/getMyHumanInfoList",
    method: "post",
    data
  });
}
/** 数字人信息 */
export interface MyHumanInfoData {
  humanId: string;
  humanImageUrl: string;
  humanType: number;
  humanAnchorName: string;
  createTime: string;
  humanTaskStatus: string;
  humanTaskStageV2: string;
  humanTaskFailMessage: string;
  checkStatus: number;
}

/** 获取音色列表 */
export function getNoFailTimbreInfoList(
  data?: object
): Promise<NoFailTimbreInfoData> {
  return http.request({
    url: "/digitalHuman/getNoFailTimbreInfoList",
    method: "post",
    data
  });
}
/** 音色信息 */
export interface NoFailTimbreInfoData {
  infoList: TimbreInfoData[];
}
/** 音色信息 */
export interface TimbreInfoData {
  timbreId: string;
  timbreAnchorName: string;
  timbreVersionType: number;
  timbreTaskStatus: string;
  createTime: string;
  timbreTaskStageV2: string;
  timbreTaskFailMessage: string;
}
/** 获取用户资产详情列表 */
export function getUserAssetDetail(
  data?: object
): Promise<UserAssetDetailData> {
  return http.request({
    url: "/userCenter/getUserAssetDetail",
    method: "post",
    data
  });
}
/** 用户资产详情 */
export interface UserAssetDetailData {
  aiCoinAmount: number;
  aiCoinBalance: number;
  exTimbreAmount: number;
  exTimbreBalance: number;
  humanAmount: number;
  humanBalance: number;
  humanNormalAmount: number;
  humanNormalBalance: number;
  humanNormalCustomAmount: number;
  humanNormalCustomBalance: number;
  noTrainFreeVideoAmount: number;
  noTrainFreeVideoBalance: number;
  noTrainVideoAmount: number;
  noTrainVideoBalance: number;
  timbreAmount: number;
  timbreBalance: number;
  totalHumanAmount: number;
  totalHumanBalance: number;
  videoMakeBalance: number;
}

